package com.xiepxcc.annotation.base;

import com.xiepxcc.annotation.base.ahandle.ParamHandlerMethodArgumentResolver;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.web.method.support.HandlerMethodArgumentResolver;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

import java.util.List;

@SpringBootApplication
public class Application implements WebMvcConfigurer {
    public static void main(String[] args) {
        args = new String[1];
        args[0] = "--spring.config.name=application-base";
        SpringApplication.run(Application.class,args);
    }

    @Override
    public void addArgumentResolvers(List<HandlerMethodArgumentResolver> resolvers) {
        resolvers.add(new ParamHandlerMethodArgumentResolver());
    }
}
